package com.example.demo.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class CorsController {

	@RequestMapping(value = "/cors")
	public String corsIndex() {
		return "Hello,Cors!中国";
	}
	

	@GetMapping("/api/cors/get")
	public String get() {
		return "cors test get method";
	}

	@PostMapping("/api/cors/post")
	public String post() {
		return "cors test post method";
	}

}